import request from "@/utils/request";

// 查询
export function listParks(query) {
  return request({
    url: "/parkinglot",
    method: "get",
    params: query,
  });
}

//查询
export function getPark(id){
  return request({
    url:'/parkinglot/'+id,
    method:'get'
  })
}

//删除
export function deletePark(id){
  return request({
    url:'/parkinglot/'+id,
    method:'delete'
  })
}
// 新增
export function addPark(data){
  return request({
    url: '/parkinglot',
    method: 'post',
    data: data
  })
}

// 更新
export function updatePark(data){
  return request({
    url: '/parkinglot',
    method: 'put',
    data: data
  })
}

